time=$(shell date +"%Y-%m-%d")
allTime=$(shell date +"%Y-%m-%d_%H-%M-%S")

default:
	echo "${time}";

release:
	yarn build && make uploadprod

release235:
	yarn build && make upload235

release233:
	yarn build && make upload233

release124:
	yarn build && make upload124

uploadprod:
	ssh web@10.1.0.154 'cp -R /data/web/yzoper/dist /data/web/yzoper/dist-${time}'
	scp -r dist web@10.1.0.154:/data/web/yzoper

upload235:
	scp -r dist web@10.0.1.235:/data/web/yzoper235

upload233:
	scp -r dist web@10.0.1.233:/data/web/yzoper233

upload124:
	scp -r dist web@10.1.0.124:/data/web/yzoper

updateName235:
	ssh web@10.0.1.235 'cp -R /data/web/yzoper235/dist-${time} /data/web/yzoper235/dist-${allTime}'

updateName233:
	ssh web@10.0.1.233 'cp -R /data/web/yzoper233/dist-${time} /data/web/yzoper233/dist-${allTime}'

updateName:
	ssh web@10.1.0.154 'cp -R /data/web/yzoper/dist-${time} /data/web/yzoper/dist-${allTime}'